import re

a = 'PythonPythonPythonPython'


r = re.findall('(Python){3}', a)
print(r)
